#include "StdAfx.h"
#include "ProgressEventArgs.h"

using namespace Adaptive::Foundation;

/*--------------------------------------------------------------------------------
 * Constructor / Dispose / Destructor Methods
 *------------------------------------------------------------------------------*/
#pragma region Constructor / Dispose / Destructor Methods

ProgressEventArgs::ProgressEventArgs()
{
	_status = nullptr;
	_percentDone = 0;
}
ProgressEventArgs::ProgressEventArgs(String^ status)
{
	_status = status;
	_percentDone = 0;
}
ProgressEventArgs::ProgressEventArgs(int percentDone)
{
	_status = String::Empty;
	PercentComplete = percentDone;
}
ProgressEventArgs::ProgressEventArgs(String^ status, int percentDone)
{
	_status = status;
	PercentComplete = percentDone;
}
ProgressEventArgs::~ProgressEventArgs()
{
	_status = nullptr;
	_percentDone = 0;
}

#pragma endregion

/*--------------------------------------------------------------------------------
 * Public Properties
 *------------------------------------------------------------------------------*/
#pragma region Public Properties

String^ ProgressEventArgs::Status::get()
{
	return _status;
}
void ProgressEventArgs::Status::set( String^ value)
{
	_status = value;
}

int ProgressEventArgs::PercentComplete::get()
{
	return _percentDone;
}
void ProgressEventArgs::PercentComplete::set(int value)
{
	if (value < 0)
		_percentDone = 0;
	else if (value > 100)
		_percentDone = 100;
	else
		_percentDone = value;
}
#pragma endregion
